<?php 
$username = $this->session->userdata('username');
$password = $this->session->userdata('password');
if (empty($username) AND empty($password)){
	echo"..";
}else{
?>
<div id="wrappercontent">
	<?php foreach($users as $data): ?>
	<?php echo form_open('login/proses_update_users/'.$data->id_user); ?>
		<div class="row-fluid">
			<div class="span5">
				Name
				<p style="margin-top:5px;"><input type="text" name="nama_lengkap" value="<?php echo $data->nama_lengkap ?>"></p>
				Username
				<p style="margin-top:5px;"><input type="text" name="username" value="<?php echo $data->username ?>"></p>
				Password
				<p style="margin-top:5px;"><input type="text" name="password">
				* Jika tidak diganti dikosongkan saja
				</p>
			</div>
			<div class="span5">
				Email
				<p style="margin-top:5px;"><input type="text" name="email" value="<?php echo $data->email ?>"></p>
				No. Telp
				<p style="margin-top:5px;"><input type="text" name="no_telp" value="<?php echo $data->no_telp ?>"></p>
				Level
				<p>
				<?php
				if ($data->level=='1'){
					?>
					<label class="radio" style="float:left; margin-top:10px;">
						<input type="radio" name="level" id="level" value="1" checked>
						Adminstrator
					</label>
					<label class="radio" style="float:left; margin-left:10px; margin-top:10px;">
						<input type="radio" name="level" id="level" value="2">
						User
					</label>
					<?php 
				}
				else{
					?>
					<label class="radio" style="float:left; margin-top:10px;">
						<input type="radio" name="level" id="level" value="1">
						Adminstrator
					</label>
					<label class="radio" style="float:left; margin-left:10px; margin-top:10px;">
						<input type="radio" name="level" id="level" value="2" checked>
						User
					</label>
					<?php 
				}
				?>	
				</p>
			</div>
		</div>
		<p style="margin-top:20px;">
			<input type="submit" value="Update" class="btn btn-danger">
		</p>
	<?php echo form_close(); ?>
	<?php endforeach ?>
</div>
<?php
}
?>